<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml" 
      xmlns:h="http://java.sun.com/jsf/html" 
      xmlns:f="http://java.sun.com/jsf/core" 
      xmlns:ui="http://java.sun.com/jsf/facelets" 
      xmlns:a4j="http://richfaces.org/a4j" 
      xmlns:rich="http://richfaces.org/rich"> 

<h:head>

<script src="resources/javascript/jquery-1.4.2.js"></script>
<script src="resources/javascript/jquery.hotkeys.js"></script>
        
 <h:outputScript>
        function containsFilter(subString, value){
            if(subString.length>=1) {
                if(value.indexOf(subString)!=-1) 
                    return true;
            }else return false;
        };

    </h:outputScript>
</h:head> 
<body>
           		<rich:panel  id="mainPanal">
				       <f:facet name="header">
				             #{msgs.salesapp}
				       </f:facet> 
				       
<h:form id="myform">

<h:outputText value="#{saleBacking.saleSavingStatus}" id="status_msg" />
<a4j:status>
            <f:facet name="start">
                <h:graphicImage value="resources/images/ai.gif" alt="ai"/>
            </f:facet>
</a4j:status>
                				       
		<h:panelGrid columns="4" id="panalid">
				
			<h:outputLabel value="الوصف" for="desc" />
            <h:inputText id="desc" value="#{saleBacking.sale.note}" title="الوصف" tabindex="0"/>
            
            <h:outputLabel value="تاريخ الاستحقاق" for="date1" />       
            <rich:calendar id="date1" enableManualInput="false" value="#{saleBacking.sale.saleDate}"/>
            
            
            <h:outputLabel value="رقم القيد" for="reg_numb" />
            <h:inputText id="reg_numb" value="#{saleBacking.sale.jvNo}" title="رقم القيد" />
            
            <h:outputLabel value="الإجمالى" for="totalid" />            
			<h:inputText value="#{saleBacking.sale.total}" id="totalid"/>  
 		</h:panelGrid>

				
			<br/>
				
			      <a4j:commandButton value="save with Ajax" action="#{saleBacking.insertSale_test}"  render="myform"/>
			      <h:commandButton action="#{saleBacking.insertSale_test}" value="submit" type="submit"  execute="@form"/>		
			</h:form>
					 
				</rich:panel>
							
			
</body> 
</html>


